package com.example.light.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.light.system.entity.permission;
import com.example.light.system.entity.user;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.ArrayList;
import java.util.HashSet;
import java.util.List;

@Mapper
@Repository
public interface PermissionMapper extends BaseMapper<permission> {
    // 批量查询父路由id
    HashSet batchQueryParentId(@Param("permissionSet")List permissionSet);

    // 通过角色id查询权限id
    ArrayList<Integer> selectByRoleId(@Param("roleId") Integer roleId);
}
